package com.bestcem.xm.member.grpc.service.param.export;

import com.bestcem.xm.common.core.constant.RegTypes;
import com.bestcem.xm.member.enums.MemberTypeEnum;
import com.bestcem.xm.member.grpc.service.param.PageParam;
import com.bestcem.xm.member.grpc.service.param.SortParam;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

import javax.validation.Valid;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import java.util.List;

/**
 * @author dc.wang <dc.wang@idiaoyan.com>
 * @version V1.0
 * @description 导出记录列表请求参数
 * @date 2021/7/29
 */
@Getter
@Setter
@ToString
public class ListExportRecordsParam {
    // 企业标识
    @NotBlank
    @Pattern(regexp = RegTypes.OBJECT_ID, message = "企业标识格式错误")
    private String orgId;

    // 操作人Id
    @NotBlank
    @Pattern(regexp = RegTypes.OBJECT_ID, message = "用户标识格式错误")
    private String opUserId;

    // 联系人类型
    @NotNull(message = "联系人类型不存在")
    private MemberTypeEnum memberTypeEnum;

    // 排序参数
    private List<SortParam> sortParams;

    // 分页参数
    @NotNull
    @Valid
    private PageParam pageParam;
}
